home *** CD-ROM | disk | FTP | other *** search
- Path: news.blkbox.COM!usenet
- From: barnowl@blkbox.com (Ken Williams)
- Newsgroups: vmsnet.misc,comp.lang.c
- Subject: Re: How to run a C program taking command line arguments on VMS
- Date: Tue, 05 Mar 1996 02:34:13 GMT
- Organization: The Black Box, Houston, Tx (713) 480-2686
- Message-ID: <313ba705.7564890@news.blkbox.com>
- References: <4h1u5d$s5c@news.fsu.edu> <4h2oda$n7q@gap.cco.caltech.edu>
- NNTP-Posting-Host: s54.max0.houston.box.net
- X-Newsreader: Forte Agent .99d/32.182
-
- On 28 Feb 1996 23:27:38 GMT, carl@SOL1.GPS.CALTECH.EDU (Carl J Lydick)
- wrote:
-
- >In article <4h1u5d$s5c@news.fsu.edu>, meil@firnvx.firn.edu (Lynn Mei) writes:
- >=Could someone tell me how to run a C program which takes command line
- >=arguments on VAX/VMS? I have checked the FAQ about openVMS and tried the
- >=instructions. But I couldn't get it work. I don't have an openVMS mannual.
- >=Please help me!
- >=
- >=My program is like:
- >=
- >=/* myprog.c */
- >=
- >= main(argn, **argv)
- >= {
- >=
- >= ...
- >=
- >= }
- >=
- >=If run on Unix or DOS, I could type something like
- >=
- >= myprog -lu abcd
- >=
- >=How to run it on VMS?
- >=
- >=I'd appreciate your help!
- >
- >From the FAQ which you claim to have read:
- >------------------------------------------------------------
- >DCL1. How do I run a program with arguments?
- >
- >The RUN command does not accept arguments. To pass arguments to a program,
- >you must use what is called a "foreign command". For example:
- >
- > $ uudecode :== $disk:[dir]uudecode.exe
- > $ uudecode filespec
- >
- [snip]
-
- This discussion belongs in comp.os.vms but...
- There is another option. You can cause a program to execute as a
- foreign command with the MCR command. In the above example you could
- do:
-
- $ mcr uudecode filespec
-
- If uudecode.exe is not in sys$system then you must provide the
- complete device and directory specification of uudecode.
-
- Regards,
-
- Ken Williams
- barnowl@blkbox.com
- PGP Key Available On Request
-